/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package edu.wpi.first.wpilibj.robot;

import edu.wpi.first.wpilibj.*;

public class PrintMotor extends Motor{
    
    DriverStationLCD dlcd;
    
    String[] s = {"","","",""};
    
    public PrintMotor(DriverStationLCD dlcd){
        this.dlcd = dlcd;
    }
    
    public void setText(String msg, int which){
        s[which] = msg;
    }
    
    public void run(){
        while(true){
            print();
        }
    }
    
    public void print(){
        dlcd.println(DriverStationLCD.Line.kUser2, 1, s[0]);   // GYRO
        dlcd.println(DriverStationLCD.Line.kUser3, 1, s[1]);   // Autonymous/Manual
        dlcd.println(DriverStationLCD.Line.kUser4, 1, s[2]);   // Driving - locked out
        dlcd.println(DriverStationLCD.Line.kUser5, 1, s[3]);   // Gun - on/off
        
        dlcd.updateLCD();
    }
    
    public void reset(){
        for (int i = 0; i < 4; i++)setText("                      ", i);
        print();
    }
    
}
